package com.dkm.ou.me.domain;

import java.util.HashMap;
import java.util.Map;

import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Service;

import com.dkm.base.core.helper.SpringHelper;
import com.dkm.biz.domain.AbstractDomain;
import com.dkm.ou.me.persistence.dao.ResGrantDao;
import com.dkm.ou.me.persistence.entity.ResGrantPo;

/**
 * 对象功能:权限授予 领域对象实体
 * 开发公司:SKG.COM
 * 开发人员:蔡东渠
 * 创建时间:2014-12-12 16:21:04
 */
@Service
@Scope("prototype")
public class ResGrant extends AbstractDomain<String, ResGrantPo>{
	 
	private static final long serialVersionUID = 6348648560611052264L;
	private ResGrantDao resGrantDao = null;

	protected void init(){
		resGrantDao = SpringHelper.getBean(ResGrantDao.class);
		setDao(resGrantDao);
	}

	public void deleteByRoleId(String roleId) {
		Map<String,Object> params=new HashMap<String,Object>();
		params.put("roleId",roleId);
		resGrantDao.deleteByKey("deleteByRoleId", params);
		
	}	 
	 
}
